#ifndef GRAPHICSDEVICE_H
#define GRAPHICSDEVICE_H

#define WIN32_LEAN_AND_MEAN

#include <windows.h>

class GraphicsDevice
{
	public:
		GraphicsDevice (void) { };
		virtual ~GraphicsDevice (void) { };		

		virtual BOOL Init (HINSTANCE hInst, LPCWSTR WinTitle, UINT ScrnWidth,
						   UINT ScrnHeight, UINT ClrDepth, BOOL Fullscreen) = 0;
		virtual void BeginRendering (void) = 0;
		virtual void EndRendering (void) = 0;
		virtual void Clear (void) = 0;
		virtual void SetClearColor (int Red, int Green, int Blue, int Alpha) = 0;
		virtual BOOL HandleWindowEvents (void);

		virtual void* GetDrawDevice (void) = 0;

		UINT GetScreenWidth (void)  { return ScreenWidth; }
		UINT GetScreenHeight (void) { return ScreenHeight; }
		UINT GetColorDepth (void)   { return ColorDepth; }
		BOOL GetFullScreen (void)   { return FullScreen; }

	protected:
		virtual BOOL InitWindow (void);
		void DisplayWindow (void);

		HINSTANCE hInstance;
		HWND hWnd;
		BOOL FullScreen;
		LPCWSTR WindowTitle;
		UINT ScreenWidth, ScreenHeight;
		UINT ColorDepth;
		MSG Msg;
};

#endif